home *** CD-ROM | disk | FTP | other *** search
- /* Demonstrates a second way to read serial chars via inactivity(). */
- /* This scripts sends all data that is received within NComm */
- /* to the current CLI window. Must be executed with the RX command */
-
- options results /* Turn on result codes */
-
- address 'ncomm' /* Our port name */
-
- inactivity 2 /* Even if we didn't receive a linefeed, we will get a copy
- of the last (current) line after 2 seconds of inactivity.
- If you only want to receive a line when a linefeed is
- received, set inactivity to 0 */
-
- do forever /* for (;;) */
- wait '0A'X /* Wait for next line */
- if RC == 20 then exit /* Exit if user selected Quit NComm */
- say result /* Write line to CLI window */
- end
-